package com.morningstar.qs.basic.db.bean;

import java.util.Date;

import org.apache.commons.beanutils.BeanUtils;

import com.morningstar.qs.basic.db.util.BeanBase;

public class MessageMember extends BeanBase implements  java.io.Serializable{

	/**
	 * 
	 */
	private static final long serialVersionUID = 3737307611720520644L;

	private int messageId;
	private int memberUserId;
	private short memberType;
	private String memberAddress;
	private short messageStatus;
	private Date createTime;
	
	private UserMessageInfo userMessageInfo;
	
	
	public UserMessageInfo transientUserMessageInfo;
	public UserMessageInfo getUserMessageInfo() {
		return userMessageInfo;
	}

	public void setUserMessageInfo(UserMessageInfo userMessageInfo) {
		this.userMessageInfo = userMessageInfo;
	}

	public UserMessageInfo getTransientUserMessageInfo() {
		return transientUserMessageInfo;
	}

	public void setTransientUserMessageInfo(UserMessageInfo transientUserMessageInfo) {
		this.transientUserMessageInfo = transientUserMessageInfo;
	}

	public int getMessageId() {
		return messageId;
	}

	public void setMessageId(int messageId) {
		this.messageId = messageId;
	}

	public int getMemberUserId() {
		return memberUserId;
	}

	public void setMemberUserId(int memberUserId) {
		this.memberUserId = memberUserId;
	}

	public short getMemberType() {
		return memberType;
	}

	public void setMemberType(short memberType) {
		this.memberType = memberType;
	}

	public String getMemberAddress() {
		return memberAddress;
	}

	public void setMemberAddress(String memberAddress) {
		this.memberAddress = memberAddress;
	}

	public short getMessageStatus() {
		return messageStatus;
	}

	public void setMessageStatus(short messageStatus) {
		this.messageStatus = messageStatus;
	}

	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	public MessageMember(int messageId, int memberUserId, short memberType,
			String memberAddress, short messageStatus, Date createTime) {
		super();
		this.messageId = messageId;
		this.memberUserId = memberUserId;
		this.memberType = memberType;
		this.memberAddress = memberAddress;
		this.messageStatus = messageStatus;
		this.createTime = createTime;
	}

	public MessageMember(){
	
	}
	
	public MessageMember toDto() {
		MessageMember dto=null;
		
		try {
			dto=new MessageMember();
			BeanUtils.copyProperties(dto, this);
		} catch (Exception e) {
			e.printStackTrace();
		} 
		return dto;
	}
	
	
	
}
